import org.testng.Assert;
import org.testng.annotations.Test;
public class UserServiceIntegrationTest {
    @Test
    public void testLoginSuccess() {
        UserDao userDao = new UserDao();
        UserService userService = new UserService(userDao);
        boolean loginSuccess = userService.login("admin", "123456");
        Assert.assertTrue(loginSuccess, "⽤户输⼊正确的账号密码，应登录成功");
    }
    public void testLoginFailure() {
        UserDao userDao = new UserDao();
        UserService userService = new UserService(userDao);

    boolean loginSuccess = userService.login("invalidUser", "wrongPwd");
 Assert.assertFalse(loginSuccess, "⽤户输⼊错误的账号密码，应登录失败");
    }
    }
